/**
 * 
 */
package com.neal.web.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.ModelAttribute;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.servlet.mvc.support.RedirectAttributes;


/**
 * @author Neal
 * @version 1.0
 * @description 
 */
@Controller
@RequestMapping("/flash")
public class FlashController {
	
	@RequestMapping("do1")
	public String do1(@RequestParam("value") String value, RedirectAttributes redirectAttributes){
		redirectAttributes.addFlashAttribute("some",value);
		return "redirect:do2";
	}
	
	@RequestMapping("do2")
	public String doo2(@ModelAttribute("some") String some){
		System.out.println("some : " + some);
		return "index";
		
	}
	
}
